<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title>Title</title>
	</head>
	<body>
		<div id="app">
			{{name}}
		</div>
		<script src="vue.js"></script>
		<script>
			var vm = new Vue({
				data: {
					name: 'wscats'
				},
				created: function() {
					alert('实例已经创建');
				},
				beforeCompile: function() {
					alert('编译之前');
				},
				compiled: function() {
					alert('编译后');
				},
				ready: function() {
					alert('插入到文档里');
				},
				beforeDestroy: function() {
					alert('销毁之前');
				},
				destroyed: function() {
					alert('销毁完成');
				}
			});
			//手动挂载指定元素
			vm.$mount('#app');
			//销毁实例
			vm.$destroy();
		</script>
	</body>

</html>